home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 2 / Apprentice-Release2.iso / Source Code / Mark Pilgrim / Devil's Cubes 1.0.1 / source / Devil’s Cubes ƒ / Cube code / cube help.c < prev    next >
Encoding:
C/C++ Source or Header  |  1994-10-30  |  6.4 KB  |  189 lines  |  [TEXT/KAHL]

  1. /**********************************************************************\
  2.  
  3. File:        cube help.c
  4.  
  5. Purpose:    This module handles displaying the different help windows.
  6.  
  7.  
  8. Devil’s Cubes -- a simple cubes puzzle
  9. Copyright (C) 1993 Mark Pilgrim
  10.  
  11. This program is free software; you can redistribute it and/or modify
  12. it under the terms of the GNU General Public License as published by
  13. the Free Software Foundation; either version 2 of the License, or
  14. (at your option) any later version.
  15.  
  16. This program is distributed in the hope that it will be useful,
  17. but WITHOUT ANY WARRANTY; without even the implied warranty of
  18. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  19. GNU General Public License for more details.
  20.  
  21. You should have received a copy of the GNU General Public License
  22. along with this program in a file named "GNU General Public License".
  23. If not, write to the Free Software Foundation, 675 Mass Ave,
  24. Cambridge, MA 02139, USA.
  25.  
  26. \**********************************************************************/
  27.  
  28. #include "cube help.h"
  29.  
  30. void DrawHelp(int whichHelp)
  31. {
  32.     GrafPtr        curPort;
  33.     
  34.     GetPort(&curPort);
  35.     EraseRect(&(curPort->portRect));
  36.  
  37.     MoveTo(10,15);
  38.     TextFont(3);
  39.     TextSize(9);
  40.     switch (whichHelp)
  41.     {
  42.         case 0:
  43.             DrawHelpUse();
  44.             break;
  45.         case 1:
  46.             DrawHelpCopyright();
  47.             break;
  48.         case 2:
  49.             DrawHelpContact();
  50.             break;
  51.         case 3:
  52.             DrawHelpFAQ();
  53.             break;
  54.     }
  55. }
  56.  
  57. void DrawHelpUse(void)
  58. {
  59.     DrawString("\pThe Devil’s Cubes are a set of four cubes, each painted with");
  60.     MoveTo(10,27);
  61.     DrawString("\pfour colors with some colors repeated.  All four cubes are");
  62.     MoveTo(10,39);
  63.     DrawString("\pdifferent.  The object of the game is to rotate the four cubes");
  64.     MoveTo(10,51);
  65.     DrawString("\puntil the top of each Devil’s Cube is a different color than");
  66.     MoveTo(10,63);
  67.     DrawString("\pthe top of the other three cubes, and likewise for the bottom,");
  68.     MoveTo(10,75);
  69.     DrawString("\pfront, and back of each Devil’s Cube.");
  70.     MoveTo(10,99);
  71.     DrawString("\pJust above the key map is a picture of each cube, showing the");
  72.     MoveTo(10,111);
  73.     DrawString("\ptop, front, and right sides.  Above that is a picture of each");
  74.     MoveTo(10,123);
  75.     DrawString("\pcube in a mirror, showing the left, back, and bottom sides.");
  76.     MoveTo(10,135);
  77.     DrawString("\pRemember that the left and right sides are irrelevant; only the");
  78.     MoveTo(10,147);
  79.     DrawString("\ptop, bottom, front, and back sides matter.  If you get confused,");
  80.     MoveTo(10,159);
  81.     DrawString("\pun-check “Show All Sides” under the Options menu to black");
  82.     MoveTo(10,171);
  83.     DrawString("\pout the left and right sides of each cube.");
  84.     MoveTo(10,195);
  85.     DrawString("\pUse the keys indicated under each cube to rotate that cube.");
  86. }
  87.  
  88. void DrawHelpCopyright(void)
  89. {
  90.     DrawString("\pDevil’s Cubes is copyright ©1993 Mark Pilgrim.  This program");
  91.     MoveTo(10,27);
  92.     DrawString("\pis completely free; you can redistribute it and/or modify it");
  93.     MoveTo(10,39);
  94.     DrawString("\punder the terms of the GNU General Public License as published");
  95.     MoveTo(10,51);
  96.     DrawString("\pby the Free Software Foundation; either version 2 of the");
  97.     MoveTo(10,63);
  98.     DrawString("\pLicense, or (at your option) any later version.");
  99.     MoveTo(10,87);
  100.     DrawString("\pDevil’s Cubes is distributed in the hope that it will be useful,");
  101.     MoveTo(10,99);
  102.     DrawString("\pbut WITHOUT ANY WARRANTY; without even the implied");
  103.     MoveTo(10,111);
  104.     DrawString("\pwarranty of MERCHANTABILITY or FITNESS FOR A");
  105.     MoveTo(10,123);
  106.     DrawString("\pPARTICULAR PURPOSE.  See the GNU General Public License");
  107.     MoveTo(10,135);
  108.     DrawString("\pfor more details.");
  109.     MoveTo(10,159);
  110.     DrawString("\pYou should have received a copy of the GNU General Public");
  111.     MoveTo(10,171);
  112.     DrawString("\pLicense along with this program; if not, write to the Free");
  113.     MoveTo(10,183);
  114.     DrawString("\pSoftware Foundation, Inc., 675 Mass Ave, Cambridge, MA,");
  115.     MoveTo(10,195);
  116.     DrawString("\p02139, USA.");
  117. }
  118.  
  119. void DrawHelpContact(void)
  120. {
  121.     DrawString("\pAll Macintosh users should feel free to contact me for any of");
  122.     MoveTo(10,27);
  123.     DrawString("\pthe following reasons: reporting bugs or suggestions about");
  124.     MoveTo(10,39);
  125.     DrawString("\pDevil’s Cubes or any other program I’ve written; discussing the");
  126.     MoveTo(10,51);
  127.     DrawString("\ppossibility of collaborating on future programming projects;");
  128.     MoveTo(10,63);
  129.     DrawString("\pdiscussing the virus I wrote and released (MBDF-A); discussing");
  130.     MoveTo(10,75);
  131.     DrawString("\pways to keep potential virus-writers from becoming actual");
  132.     MoveTo(10,87);
  133.     DrawString("\pvirus-writers; discussing techniques for really good backrubs.");
  134.     MoveTo(10,111);
  135.     DrawString("\pMy e-mail address is f8dy@netaxs.com.  To send me e-mail");
  136.     MoveTo(10,123);
  137.     DrawString("\panonymously, mail to an48382@anon.penet.fi.  (Due to the");
  138.     MoveTo(10,135);
  139.     DrawString("\pdouble-blind system, you will be allocated an anonymous I.D.");
  140.     MoveTo(10,147);
  141.     DrawString("\pwhich will keep your identity hidden.)  To send me encrypted");
  142.     MoveTo(10,159);
  143.     DrawString("\pmail, e-mail me requesting my PGP 2.2 public key.  If you do");
  144.     MoveTo(10,171);
  145.     DrawString("\pnot have e-mail access, my home address is 1130 Radnor Hill");
  146.     MoveTo(10,183);
  147.     DrawString("\pRoad, Wayne PA, 19087-2203, USA.  Obviously, it will take");
  148.     MoveTo(10,195);
  149.     DrawString("\pme much longer to reply to snail-mail; use it as a last resort.");
  150. }
  151.  
  152. void DrawHelpFAQ(void)
  153. {
  154.     MoveTo(5,15);
  155.     TextFace(bold);
  156.     DrawString("\pWhy is my copy of Devil’s Cubes registered to Bob?");
  157.     MoveTo(10,27);
  158.     TextFace(0);
  159.     DrawString("\pThat’s the default name the program uses if you don’t enter");
  160.     MoveTo(10,39);
  161.     DrawString("\pyour name in the personalization dialog box.");
  162.     MoveTo(5,63);
  163.     TextFace(bold);
  164.     DrawString("\pHow do I re-personalize my copy of Devil’s Cubes?");
  165.     MoveTo(10,75);
  166.     TextFace(0);
  167.     DrawString("\pDuplicate it or copy it to another disk, then run the copy.");
  168.     MoveTo(10, 87);
  169.     DrawString("\p(Or just trash “Devil’s Cubes prefs” in your system folder.)");
  170.     MoveTo(5,111);
  171.     TextFace(bold);
  172.     DrawString("\pWhy all the fuss over the MBDF-A virus?");
  173.     MoveTo(10,123);
  174.     TextFace(0);
  175.     DrawString("\pI’m trying to put back into the Macintosh community as much");
  176.     MoveTo(10,135);
  177.     DrawString("\pas I took out of it.  When I reach the break-even point, I’ll");
  178.     MoveTo(10,147);
  179.     DrawString("\plet you know.");
  180.     MoveTo(5,171);
  181.     TextFace(bold);
  182.     DrawString("\pHow does MSG enhance the flavor of my Macintosh?");
  183.     MoveTo(10,183);
  184.     TextFace(0);
  185.     DrawString("\pWe try to think of things that no other Macintosh program");
  186.     MoveTo(10,195);
  187.     DrawString("\pdoes, and then we do them.  Any suggestions?");
  188. }
  189.